package com.reader.api.service.impl.magazine;

import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import com.reader.api.entity.magazine.ReaderMagazine;
import com.reader.api.mapper.magazine.ReaderMagazineMapper;
import com.reader.api.service.magazine.IReaderMagazineService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.HashMap;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;

/**
 * @@description  服务实现类
 * @author        jiahaikun
 * @date          2018-11-06
 */
@Service
@Transactional
public class ReaderMagazineServiceImpl extends ServiceImpl<ReaderMagazineMapper, ReaderMagazine> implements IReaderMagazineService {


@Autowired
private ReaderMagazineMapper readerMagazineMapper;


    @Override
    public List<Map<String, Object>> selectPeriodListPage(Integer period) {
            return readerMagazineMapper.selectPeriodListPage(period);
    }

    @Override
    public List<HashMap<String, Object>> selectYearListPage() {
        return readerMagazineMapper.selectYearListPage();
    }

    @Override
    public List<LinkedHashMap<String, Object>> selectColumnListPage(String magazineId) {
        return readerMagazineMapper.selectColumnListPage(magazineId);
    }

}